Because the brain forgets,
🤖in-v-bat-ai
🧠Recall
Mission
Traveling Salesman Problem 7 Cities
Never Forget Again

🌍 Trusted by 243,234 learners in 149 countries


A synapse is the tiny gap where one neuron passes information to the next.

Your brain stores knowledge in neuron connections called synapses. When those connections or links fade, you forget.
THE SOLUTION: IN-V-BAT- AI


Try It Now. Only $1



Adjacency Matrix Visualizer + Deterministic Path Engine

The Traveling Salesman Problem (TSP) and Hamiltonian Path/Cycle problems are closely related, but they are not the same thing.

Travelling Salesman Problem — Route Count Formulas

In a travelling salesman problem with 7 cities, the goal is to find the shortest possible route that starts at City A, visits each of the remaining six cities exactly once, and returns to City A.

Directed Graph (Ordered Routes)

The number of possible directed tours is given by:

P(n) = (n − 1)!

For seven cities:

P(7) = 6! = 720

Undirected Graph (Unique Routes)

In an undirected TSP, a route and its reverse direction represent the same path. To remove these duplicates, the number of unique tours is:

U(n) = (n − 1)! / 2

For seven cities:

U(7) = 6! / 2 = 360

This means there are 360 unique undirected tours when reverse paths are treated as identical.


Explainable AI Diagram

Click any cell to edit its weight. Use 1e9 to mark a forbidden transition.

Node labels

Matrix JSON

Reasoning trace